// rxreducer

const initialState = {
    data:[],
    table_loading:true
}

export default (state = initialState, { type, payload }) => {
    let newState = JSON.parse(JSON.stringify(state))
    switch (type) {
        case "GET_TABLE":
            newState.data = payload.data
            newState.table_loading = payload.loading
            return newState

        default:
            return newState
    }
}
